#include <LowMemShadowPass.h>
Public Member Functions | |
LowMemShadowPass (void) | |
~LowMemShadowPass (void) | |
virtual void | executePass () |
void | setActiveLight (LowMemLight *_light) |
int | getNbDepthMaps () |
IDirect3DTexture9 * | getDepthMapAt (int id) |
Public Attributes | |
bool | smartReprojection |
int | maxUsedMaps |
Protected Member Functions | |
void | releaseLowResMap (depthMapNode node) |
void | resetLowResMaps () |
void | clearSumTexture (bool onlyDepth) |
void | createDepthMap (depthMapNode &node) |
void | refineShadow (depthMapNode leftNode, depthMapNode rightNode, int level) |
void | shadeAndReproject (depthMapNode &node, bool reproject, D3DXMATRIX refMatrix) |
void | calcMatrices (depthMapNode &node) |
bool | isQualityOkay (depthMapNode leftNode, depthMapNode rightNode) |
void | calcDifference (IDirect3DTexture9 *leftMap, IDirect3DTexture9 *rightMap) |
void | bigPCFShadow (depthMapNode leftNode) |
Classes | |
struct | depthMapNode |
LowMemShadowPass::LowMemShadowPass | ( | void | ) |
Constructor of the SoftShadow Renderpass
LowMemShadowPass::~LowMemShadowPass | ( | void | ) |
Destructor of the SoftShadow Renderpass
void LowMemShadowPass::executePass | ( | ) | [virtual] |
Starts the calculation of the softshadow
Reimplemented from RenderPass.
void LowMemShadowPass::setActiveLight | ( | LowMemLight * | _light | ) |
Activates the current light
int LowMemShadowPass::getNbDepthMaps | ( | ) |
Returns the number of depthMaps
IDirect3DTexture9 * LowMemShadowPass::getDepthMapAt | ( | int | id | ) |
Returns depthMap with given id
void LowMemShadowPass::releaseLowResMap | ( | depthMapNode | node | ) | [protected] |
Releases a depthMap
void LowMemShadowPass::resetLowResMaps | ( | ) | [protected] |
Resets all depthMaps
void LowMemShadowPass::clearSumTexture | ( | bool | onlyDepth | ) | [protected] |
clears the Sum Textures
void LowMemShadowPass::createDepthMap | ( | depthMapNode & | node | ) | [protected] |
Creates or reuses a available depthMap
void LowMemShadowPass::refineShadow | ( | depthMapNode | leftNode, | |
depthMapNode | rightNode, | |||
int | level | |||
) | [protected] |
Subdivides the space between two shadow maps (by generating a new shadowmap)
void LowMemShadowPass::shadeAndReproject | ( | depthMapNode & | node, | |
bool | reproject, | |||
D3DXMATRIX | refMatrix | |||
) | [protected] |
Performes the shadowshading and the previous reprojection to check against the error bound
void LowMemShadowPass::calcMatrices | ( | depthMapNode & | node | ) | [protected] |
Calculates the needed matrices for a given depthMap node
bool LowMemShadowPass::isQualityOkay | ( | depthMapNode | leftNode, | |
depthMapNode | rightNode | |||
) | [protected] |
Uses occlusion queries to calculate differences between two shadowmaps and returns if a refinement is needed
void LowMemShadowPass::calcDifference | ( | IDirect3DTexture9 * | leftMap, | |
IDirect3DTexture9 * | rightMap | |||
) | [protected] |
Performs the rendering code for difference calculation
void LowMemShadowPass::bigPCFShadow | ( | depthMapNode | leftNode | ) | [protected] |
Renders the scene with one shadowmap using a big PCF kernel
Activate smartReprojection to reduce the number of depthMaps by one. Be aware: This is a feature in alpha state!
Number of maximum used depthMaps